package com.probiz.estoresa.product.web.action;

import javax.servlet.http.HttpServletRequest;

import org.springframework.validation.BindException;

import com.probiz.estore.common.model.product.ProductStat;
import com.probiz.estore.core.controller.GenericStoreAdminController;
import com.probiz.estore.product.service.ProductStatManager;

public class ProductStatController extends GenericStoreAdminController<ProductStat> {
    private ProductStatManager productStatManager = null;

    public void setProductStatManager(ProductStatManager inMgr) {
        this.productStatManager = inMgr;
    }

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.probiz.estore.core.controller.GenericController#getEntityName(java.lang.Object)
	 */
	@Override
	protected String getEntityName(ProductStat entity) {
		return entity.getProductStatName();
	}


	/*
	 * (non-Javadoc)
	 * 
	 * @see com.probiz.estore.core.controller.BaseController#initController()
	 */
	@Override
	protected void initController() throws Exception {
		mgr = productStatManager;
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.probiz.estore.core.controller.GenericController#preSave(javax.servlet.http.HttpServletRequest,
	 *      java.lang.Object, org.springframework.validation.BindException)
	 */
	@Override
	protected void preSave(HttpServletRequest request, ProductStat entity, BindException errors) {
	}

}
